// pages/info/info.js
import { userBehavior } from '../../behaviors/userBehavior'

Page({
  behaviors: [userBehavior],

  // 页面的初始数据
  data: {
    // 初始化第二个面板数据
    initpanel: [
      {
        url: '/pages/customer_order_list/index',
        title: '商品订单',
        iconfont: 'notes-o'
      },
      {
        url: '/pages/customer_my/discount/index',
        title: '优惠卷',
        iconfont: 'gem-o'
      },
      {
        url: '/pages/customer_return_order_list/index',
        title: '退款/售后',
        iconfont: 'refund-o'
      }
    ]
  },

  // 跳转到登录页面
  toLoginPage() {
    wx.navigateTo({
      url: '/pages/pre_index/index'
    })
  },
  // 跳转我的订单列表
  myOrderList(){
    wx.navigateTo({
      url: '/pages/customer_order_list/index'
    })
  },
  onShow() {
    this.getTabBar().setData({
      active: 3
    })
  },
})
